# Sets the minimum version of CMake required to build the native
# library. You should either keep the default value or only pass a
# value of 3.4.0 or lower.

cmake_minimum_required(VERSION 3.4.1)

set(ANDROID_LIBS_DIR "/Users/mac/Downloads/Library")
set(USER_LIBRARY_DIR "/Users/mac/Downloads/Library/libzhouyb/zhou_yb")
set(CMAKE_LIBRARY_OUTPUT_DIRECTORY ${PROJECT_SOURCE_DIR}/libs/${ANDROID_ABI})

set(CMAKE_C_FLAGS_RELEASE "${CMAKE_C_FLAGS_RELEASE} -s")
set(CMAKE_CXX_FLAGS_RELEASE "${CMAKE_CXX_FLAGS_RELEASE} -s")

add_library(HardwareDriver
    SHARED
    src/main/cpp/com_hardware_h003_HardwareDriver.cpp)

add_library(ComDevice
    SHARED
    src/main/cpp/com_lc_driver_JniComTransmitHandler.cpp)

target_link_libraries(HardwareDriver
    ${ANDROID_LIBS_DIR}/libs/libiconv-1.14_a.a
    #${ANDROID_LIBS_DIR}/libs/libwlt2bmp.so
    )

include_directories(${ANDROID_LIBS_DIR}/libiconv-1.14/include)
include_directories(${USER_LIBRARY_DIR})
include_directories(${USER_BOOST_DIR})
include_directories(./cpp)